﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;

namespace DFYE.Web.Models
{
    public partial class guestBook
    {
        public string getIP()
        {
            if (string.IsNullOrWhiteSpace(ip)) return "未知";
            var _ip = this.ip.Split('.');
            if (_ip.Length != 4) return "未知";
            _ip[2] = "xxx";
            _ip[3] = "xxx";
            return string.Join(".", _ip);            
        }
    }
}